{"ast":null,"code":"import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nvar _excluded = [\"action\", \"children\", \"component\", \"disabled\", \"focusableWhenDisabled\", \"onBlur\", \"onClick\", \"onFocus\", \"onFocusVisible\", \"onKeyDown\", \"onKeyUp\", \"onMouseLeave\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport composeClasses from '../composeClasses';\nimport { getButtonUnstyledUtilityClass } from './buttonUnstyledClasses';\nimport useButton from './useButton';\nimport { useSlotProps } from '../utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nvar useUtilityClasses = function useUtilityClasses(ownerState) {\n  var active = ownerState.active,\n    disabled = ownerState.disabled,\n    focusVisible = ownerState.focusVisible;\n  var slots = {\n    root: ['root', disabled && 'disabled', focusVisible && 'focusVisible', active && 'active']\n  };\n  return composeClasses(slots, getButtonUnstyledUtilityClass, {});\n};\n/**\n * The foundation for building custom-styled buttons.\n *\n * Demos:\n *\n * - [Unstyled Button](https://mui.com/base/react-button/)\n *\n * API:\n *\n * - [ButtonUnstyled API](https://mui.com/base/api/button-unstyled/)\n */\nvar ButtonUnstyled = /*#__PURE__*/React.forwardRef(function ButtonUnstyled(props, forwardedRef) {\n  var _ref;\n  var action = props.action,\n    children = props.children,\n    component = props.component,\n    _props$focusableWhenD = props.focusableWhenDisabled,\n    focusableWhenDisabled = _props$focusableWhenD === void 0 ? false : _props$focusableWhenD,\n    _props$slotProps = props.slotProps,\n    slotProps = _props$slotProps === void 0 ? {} : _props$slotProps,\n    _props$slots = props.slots,\n    slots = _props$slots === void 0 ? {} : _props$slots,\n    other = _objectWithoutPropertiesLoose(props, _excluded);\n  var buttonRef = React.useRef();\n  var _useButton = useButton(_extends({}, props, {\n      focusableWhenDisabled: focusableWhenDisabled\n    })),\n    active = _useButton.active,\n    focusVisible = _useButton.focusVisible,\n    setFocusVisible = _useButton.setFocusVisible,\n    getRootProps = _useButton.getRootProps;\n  React.useImperativeHandle(action, function () {\n    return {\n      focusVisible: function focusVisible() {\n        setFocusVisible(true);\n        buttonRef.current.focus();\n      }\n    };\n  }, [setFocusVisible]);\n  var ownerState = _extends({}, props, {\n    active: active,\n    focusableWhenDisabled: focusableWhenDisabled,\n    focusVisible: focusVisible\n  });\n  var classes = useUtilityClasses(ownerState);\n  var defaultElement = other.href || other.to ? 'a' : 'button';\n  var Root = (_ref = component != null ? component : slots.root) != null ? _ref : defaultElement;\n  var rootProps = useSlotProps({\n    elementType: Root,\n    getSlotProps: getRootProps,\n    externalForwardedProps: other,\n    externalSlotProps: slotProps.root,\n    additionalProps: {\n      ref: forwardedRef\n    },\n    ownerState: ownerState,\n    className: classes.root\n  });\n  return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n    children: children\n  }));\n});\nprocess.env.NODE_ENV !== \"production\" ? ButtonUnstyled.propTypes /* remove-proptypes */ = {\n  // ----------------------------- Warning --------------------------------\n  // | These PropTypes are generated from the TypeScript type definitions |\n  // |     To update them edit TypeScript types and run \"yarn proptypes\"  |\n  // ----------------------------------------------------------------------\n  /**\n   * A ref for imperative actions. It currently only supports `focusVisible()` action.\n   */\n  action: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n    current: PropTypes.shape({\n      focusVisible: PropTypes.func.isRequired\n    })\n  })]),\n  /**\n   * @ignore\n   */\n  children: PropTypes.node,\n  /**\n   * The component used for the root node.\n   * Either a string to use a HTML element or a component.\n   */\n  component: PropTypes.elementType,\n  /**\n   * If `true`, the component is disabled.\n   * @default false\n   */\n  disabled: PropTypes.bool,\n  /**\n   * If `true`, allows a disabled button to receive focus.\n   * @default false\n   */\n  focusableWhenDisabled: PropTypes.bool,\n  /**\n   * @ignore\n   */\n  href: PropTypes.string,\n  /**\n   * @ignore\n   */\n  onBlur: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onClick: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onFocus: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onFocusVisible: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onKeyDown: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onKeyUp: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onMouseLeave: PropTypes.func,\n  /**\n   * The props used for each slot inside the Button.\n   * @default {}\n   */\n  slotProps: PropTypes.shape({\n    root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n  }),\n  /**\n   * The components used for each slot inside the Button.\n   * Either a string to use a HTML element or a component.\n   * @default {}\n   */\n  slots: PropTypes.shape({\n    root: PropTypes.elementType\n  }),\n  /**\n   * @ignore\n   */\n  to: PropTypes.string\n} : void 0;\nexport default ButtonUnstyled;","map":{"version":3,"names":["_extends","_objectWithoutPropertiesLoose","_excluded","React","PropTypes","composeClasses","getButtonUnstyledUtilityClass","useButton","useSlotProps","jsx","_jsx","useUtilityClasses","ownerState","active","disabled","focusVisible","slots","root","ButtonUnstyled","forwardRef","props","forwardedRef","_ref","action","children","component","focusableWhenDisabled","slotProps","other","buttonRef","useRef","setFocusVisible","getRootProps","useImperativeHandle","current","focus","classes","defaultElement","href","to","Root","rootProps","elementType","getSlotProps","externalForwardedProps","externalSlotProps","additionalProps","ref","className","process","env","NODE_ENV","propTypes","oneOfType","func","shape","isRequired","node","bool","string","onBlur","onClick","onFocus","onFocusVisible","onKeyDown","onKeyUp","onMouseLeave","object"],"sources":["/Users/poppie/Desktop/development/messenger/app/frontend/node_modules/@mui/base/ButtonUnstyled/ButtonUnstyled.js"],"sourcesContent":["import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nconst _excluded = [\"action\", \"children\", \"component\", \"disabled\", \"focusableWhenDisabled\", \"onBlur\", \"onClick\", \"onFocus\", \"onFocusVisible\", \"onKeyDown\", \"onKeyUp\", \"onMouseLeave\", \"slotProps\", \"slots\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport composeClasses from '../composeClasses';\nimport { getButtonUnstyledUtilityClass } from './buttonUnstyledClasses';\nimport useButton from './useButton';\nimport { useSlotProps } from '../utils';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n  const {\n    active,\n    disabled,\n    focusVisible\n  } = ownerState;\n  const slots = {\n    root: ['root', disabled && 'disabled', focusVisible && 'focusVisible', active && 'active']\n  };\n  return composeClasses(slots, getButtonUnstyledUtilityClass, {});\n};\n/**\n * The foundation for building custom-styled buttons.\n *\n * Demos:\n *\n * - [Unstyled Button](https://mui.com/base/react-button/)\n *\n * API:\n *\n * - [ButtonUnstyled API](https://mui.com/base/api/button-unstyled/)\n */\nconst ButtonUnstyled = /*#__PURE__*/React.forwardRef(function ButtonUnstyled(props, forwardedRef) {\n  var _ref;\n  const {\n      action,\n      children,\n      component,\n      focusableWhenDisabled = false,\n      slotProps = {},\n      slots = {}\n    } = props,\n    other = _objectWithoutPropertiesLoose(props, _excluded);\n  const buttonRef = React.useRef();\n  const {\n    active,\n    focusVisible,\n    setFocusVisible,\n    getRootProps\n  } = useButton(_extends({}, props, {\n    focusableWhenDisabled\n  }));\n  React.useImperativeHandle(action, () => ({\n    focusVisible: () => {\n      setFocusVisible(true);\n      buttonRef.current.focus();\n    }\n  }), [setFocusVisible]);\n  const ownerState = _extends({}, props, {\n    active,\n    focusableWhenDisabled,\n    focusVisible\n  });\n  const classes = useUtilityClasses(ownerState);\n  const defaultElement = other.href || other.to ? 'a' : 'button';\n  const Root = (_ref = component != null ? component : slots.root) != null ? _ref : defaultElement;\n  const rootProps = useSlotProps({\n    elementType: Root,\n    getSlotProps: getRootProps,\n    externalForwardedProps: other,\n    externalSlotProps: slotProps.root,\n    additionalProps: {\n      ref: forwardedRef\n    },\n    ownerState,\n    className: classes.root\n  });\n  return /*#__PURE__*/_jsx(Root, _extends({}, rootProps, {\n    children: children\n  }));\n});\nprocess.env.NODE_ENV !== \"production\" ? ButtonUnstyled.propTypes /* remove-proptypes */ = {\n  // ----------------------------- Warning --------------------------------\n  // | These PropTypes are generated from the TypeScript type definitions |\n  // |     To update them edit TypeScript types and run \"yarn proptypes\"  |\n  // ----------------------------------------------------------------------\n  /**\n   * A ref for imperative actions. It currently only supports `focusVisible()` action.\n   */\n  action: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({\n    current: PropTypes.shape({\n      focusVisible: PropTypes.func.isRequired\n    })\n  })]),\n  /**\n   * @ignore\n   */\n  children: PropTypes.node,\n  /**\n   * The component used for the root node.\n   * Either a string to use a HTML element or a component.\n   */\n  component: PropTypes.elementType,\n  /**\n   * If `true`, the component is disabled.\n   * @default false\n   */\n  disabled: PropTypes.bool,\n  /**\n   * If `true`, allows a disabled button to receive focus.\n   * @default false\n   */\n  focusableWhenDisabled: PropTypes.bool,\n  /**\n   * @ignore\n   */\n  href: PropTypes.string,\n  /**\n   * @ignore\n   */\n  onBlur: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onClick: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onFocus: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onFocusVisible: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onKeyDown: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onKeyUp: PropTypes.func,\n  /**\n   * @ignore\n   */\n  onMouseLeave: PropTypes.func,\n  /**\n   * The props used for each slot inside the Button.\n   * @default {}\n   */\n  slotProps: PropTypes.shape({\n    root: PropTypes.oneOfType([PropTypes.func, PropTypes.object])\n  }),\n  /**\n   * The components used for each slot inside the Button.\n   * Either a string to use a HTML element or a component.\n   * @default {}\n   */\n  slots: PropTypes.shape({\n    root: PropTypes.elementType\n  }),\n  /**\n   * @ignore\n   */\n  to: PropTypes.string\n} : void 0;\nexport default ButtonUnstyled;"],"mappings":"AAAA,OAAOA,QAAQ,MAAM,oCAAoC;AACzD,OAAOC,6BAA6B,MAAM,yDAAyD;AACnG,IAAMC,SAAS,GA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kD,IAAI;EAC9B;AACF;AACA;EACEU,SAAS,EAAE5D,SAAS,CAACkD,IAAI;EACzB;AACF;AACA;EACEW,OAAO,EAAE7D,SAAS,CAACkD,IAAI;EACvB;AACF;AACA;EACEY,YAAY,EAAE9D,SAAS,CAACkD,IAAI;EAC5B;AACF;AACA;AACA;EACE3B,SAAS,EAAEvB,SAAS,CAACmD,KAAK,CAAC;IACzBtC,IAAI,EAAEb,SAAS,CAACiD,SAAS,CAAC,CAACjD,SAAS,CAACkD,IAAI,EAAElD,SAAS,CAAC+D,MAAM,CAAC;EAC9D,CAAC,CAAC;EACF;AACF;AACA;AACA;AACA;EACEnD,KAAK,EAAEZ,SAAS,CAACmD,KAAK,CAAC;IACrBtC,IAAI,EAAEb,SAAS,CAACsC;EAClB,CAAC,CAAC;EACF;AACF;AACA;EACEH,EAAE,EAAEnC,SAAS,CAACuD;AAChB,CAAC,GAAG,KAAK,CAAC;AACV,eAAezC,cAAc"},"metadata":{},"sourceType":"module"}